/**
 * File: router.js
 * Project: App
 * Created Date: Wednesday 2018/03/07 11:27:09
 * Author: zhengjiang
 * -----
 * Last Modified: Monday 2018/03/12 15:15:19
 * Modified By: zhengjiang
 * -----
 * Description: 
 * 
 */

import * as React from 'react';
import { StatusBar } from 'react-native';
import { TabNavigator, StackNavigator, NavigationActions, addNavigationHelpers } from 'react-navigation';
// 先引入这个方法(让安卓实现push动画)
import CardStackStyleInterpolator from 'react-navigation/src/views/CardStack/CardStackStyleInterpolator';

import Camera from './camera';
import ImagePicker from './ImagePicker';
import Photos from './Photos';
import Home from './Home';
import AlbumView from './AlbumView';
const Router = StackNavigator(
	{
		Home: {
			screen: Home
		},
		Camera: {
			screen: Camera
		},
		ImagePicker: {
			screen: ImagePicker
		},
		Photos: {
			screen: Photos
		},
		AlbumView:{
			screen:AlbumView
		}
	},
	{
		initialRouteName: 'Home',
		navigationOptions: {
			header: null /* <StatusBar hidden={true} /> */,
			// gesturesEnabled: false //是否支持滑动返回，iOS默认支持，安卓默认关闭
		},
		transitionConfig: () => ({
			screenInterpolator: CardStackStyleInterpolator.forHorizontal
		})
	}
);

class Routers extends React.Component {
	constructor(props) {
		super(props);
	}

	render() {
		return <Router />;
	}
}

export default Routers;
